define([],function(){
	var tpl = {};

	tpl.search = function(){
		var html = "";
		html += search();
		return html;
	}
	tpl.result = function(){
		var html = "";
		html += result();
		return html;
	}

	var search = function(){
		return 	'<script id="dstList_search" type="text/html">'+
				'	<div class="dstlist-modal">'+
				'	    <div class="input-group">'+
				'	      	<input id="searchText" type="text" class="form-control" placeholder="请输入姓名或者手机号">'+
				'	      	<span class="input-group-btn">'+
				'	        	<button id="searchBtn" class="btn btn-default" type="button">'+
				'					<i class="fa fa-search" aria-hidden="true"></i>'+
				'				</button>'+
				'	     	</span>'+
				'	    </div>'+
				'		<div id="dstlistSearchResult" class="dstlist-result"></div>'+
				'		<p class="dstlist-tips">适用年龄：0-72月龄</p>'+
				'	</div>'+
				'</script>';
	}

	var result = function(){
		return 	'<script id="dstList_result" type="text/html">'+
				'	{{if list.length > 0}}'+
				'		<ul class="dstlist-patients">'+
				'			{{each list as value}}'+
				'			<li data-patientId="{{value.patientId}}">'+
				'				<span>{{value.patientName}}</span>'+
				'				{{if value.gender == "F"}}'+
				'					<span class="sex sex-girl">女</span>'+
				'				{{else}}'+
				'					<span class="sex sex-boy">男</span>'+
				'				{{/if}}'+
				'				<span>{{value.age}}</span>'+
				'				<span>{{value.phoneNum}}</span>'+
				'			</li>'+
				'			{{/each}}'+
				'		</ul>'+
				'	{{else}}'+
				'		<div class="dstlist-no-patients">没有搜索到！</div>'+
				'	{{/if}}'+
				'</script>';
	}

	return tpl;
});